package com.webclient.struts2;

import org.apache.struts2.convention.annotation.Action;
import org.apache.struts2.convention.annotation.Results;
import org.apache.struts2.convention.annotation.Result;
import org.springframework.beans.factory.annotation.Autowired;

import com.opensymphony.xwork2.ActionSupport;
import com.xiaotu.code.service.webservice.MathServiceClient;

@Results({@Result(name="success",location="/WEB-INF/content/test/client.jsp")})
public class TestAction extends ActionSupport{

	/**
	 * 
	 */
	private static final long serialVersionUID = 5559249917690743523L;
	
	@Autowired
	private MathServiceClient mathServiceClient;
	
	@Action("/test/client")
	public String testMethod(){
		System.out.println(mathServiceClient);
		mathServiceClient.testWebService();
		return SUCCESS;
	}

}
